The ColorPicker Component > FColorPicker.addItem()

 

FColorPicker.addItem()

Availability

Flash Player 6.

Usage

myPicker_cp.addItem (color)

Parameters

color - The color to add to the component (in 0xRRGGBB form).

Returns

Nothing.

Description

Adds a new color swatch to the ColorPicker component.

Note

In addition to addItem and removeItem, the ColorPicker component supports the same methods as the DataProvider class (such as removeItemAt, removeAll, getItemAt, and so on). See the DataProviderClass documentation for more details on these methods.

Example

The following code adds a new red swatch to an instance of the ColorPicker component:

myPicker_cp.addItem(0xFF0000);

See also

FColorPicker.addItemAt()